import request from '@/utils/request'

class groupService {

  //分组列表带分页条件
  select(params) {
    return request({
      url: '/group/select',
      method: 'post',
      data: params
    })
  }

  //分组列表所有
  list(params) {
    return request({
      url: '/group/list',
      method: 'get',
      data: params
    })
  }
  //分组添加
  add(params) {
    return request({
      url: '/group/add',
      method: 'post',
      data: params
    })
  }
  //分组获取根据id
  get(params) {
    return request({
      url: '/group/get',
      method: 'get',
      data: params
    })
  }
  //分组更新保存
  update(params) {
    return request({
      url: '/group/update',
      method: 'POST',
      data: params
    })
  }
  //分组删除
  del(params) {
    return request({
      url: '/group/del',
      method: 'post',
      data: params
    })
  }
  //获取分组符合两个条件的设备列表
  selectRelation(params) {
    return request({
      url: '/group/selectRelation',
      method: 'post',
      data: params
    })
  }

}

export default new groupService()